package com.agent.payment.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.agent.payment.entity.PaymentOrder;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * 支付订单Mapper
 * @author Jeff_Wan
 * @description 支付订单数据库操作接口
 */
@Mapper
public interface PaymentOrderMapper extends BaseMapper<PaymentOrder> {

    /**
     * 根据订单号查询订单
     * @param orderNumber 订单编号
     * @return 支付订单
     */
    @Select("SELECT * FROM payment_order WHERE order_number = #{orderNumber}")
    PaymentOrder findByOrderNumber(@Param("orderNumber") String orderNumber);
}